Skip to main content
This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal

Notes/Domino 6 and 7 Forum

Notes/Domino 6 and 7 Forum


  

PreviousPrevious NextNext


~Lex Kihipitex 24.Oct.02 05:44 AM a Web browser
Applications Development 6.0 All Platforms


Anyone tried an XSLT transformation of Notes 6 DXL ?

Below are the three parts to an XML transformation:
* The DXL Code
* The XSLT Transformation Code
* My current result (not matching attributes)

Unfortunately I'm having problems due to the NameSpace definition in the Database element (which seems to be the new default in Notes 6).
I think my problem is setting correctly the namespace around the attribute selections in the dxl:document template in the xsl file. Presently I'm not getting any matches.

FYI - it works by dropping the NameSpace definition, and the DocType. To test this you need to remove the namespace prefixes).

Any thoughts would be most appreciated.

Glenn


Source export.xml from Notes 6
<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE database SYSTEM 'c:\temp\xmlschemas\domino_6_0.dtd'>
<database xmlns='http://www.lotus.com/dxl' version='6.0' replicaid='CA256C530030F2C2'
path='GDruce\Blog.nsf' title='Blog'>
<databaseinfo dbid='CA256C530030F2C2' odsversion='43' diskspace='327680' percentused='93.515625'
numberofdocuments='1'><datamodified><datetime>20021015T212316,81+10</datetime></datamodified><designmodified
><datetime>20021016T080151,28+10</datetime></designmodified></databaseinfo>
<document form='Item'>
<noteinfo noteid='8fa' unid='4CB4639861392CDBCA256C53003E59BB' sequence='3'>
<created><datetime>20021015T212102,03+10</datetime></created>
<modified><datetime>20021015T212316,81+10</datetime></modified>
<revised><datetime>20021015T212316,80+10</datetime></revised>
<lastaccessed><datetime>20021015T212316,80+10</datetime></lastaccessed>
<addedtofile><datetime>20021015T212121,06+10</datetime></addedtofile></noteinfo>
<updatedby><name>CN=Glenn Druce/OU=Australia/O=Org</name></updatedby>
<revisions><datetime>20021015T212121,06+10</datetime><datetime>20021015T212311,69+10</datetime></revisions>
<item name='Title'><text>Title</text></item>
<item name='Description'><text>Full Description for this item.</text></item>
<item name='Link'><text>http://www.lotus.com</text></item>
<item name='TimeStamp'><datetime>20021015T212315,69+10</datetime></item></document>
<document form='Item'>
<noteinfo noteid='8fa' unid='4CB4639861392CDBCA256C53003E59BB' sequence='3'>
<created><datetime>20021015T212102,03+10</datetime></created>
<modified><datetime>20021015T212316,81+10</datetime></modified>
<revised><datetime>20021015T212316,80+10</datetime></revised>
<lastaccessed><datetime>20021015T212316,80+10</datetime></lastaccessed>
<addedtofile><datetime>20021015T212121,06+10</datetime></addedtofile></noteinfo>
<updatedby><name>CN=Glenn Druce/OU=Australia/O=Org</name></updatedby>
<revisions><datetime>20021015T212121,06+10</datetime><datetime>20021015T212311,69+10</datetime></revisions>
<item name='Title'><text>Title</text></item>
<item name='Description'><text>Full Description for this item.</text></item>
<item name='Link'><text>http://www.lotus.com</text></item>
<item name='TimeStamp'><datetime>20021015T212315,69+10</datetime></item></document>
</database>



Transforming Style Sheet export.xsl
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" xmlns:dxl="http://www.lotus.com/dxl">
<xsl:output method="html" indent="yes" />

<xsl:template match="/">
<HTML>
<HEAD>
<TITLE>Blog</TITLE>
</HEAD>
<BODY bgcolor="#ffffff" marginheight="0" marginwidth="0" leftmargin="0" topmargin="0">
<xsl:apply-templates select="dxl:database"/>
</BODY>
</HTML>
</xsl:template>

<xsl:template match="dxl:database">
<TABLE width="100%" cellpadding="0" cellspacing="0" border="0">
<xsl:apply-templates select="dxl:document"/>
</TABLE>
</xsl:template>

<xsl:template match="dxl:document">
<TR>
<TD border="0">
<A>
<xsl:attribute name="href">
<xsl:value-of select="dxl:item[@dxl:name='Link']/dxl:text"/>
</xsl:attribute>
<xsl:value-of select="dxl:item[@dxl:name='Title']/dxl:text"/><BR/>
</A>
<xsl:value-of select="dxl:item[@dxl:name='Description']/dxl:text"/>
</TD>
</TR>
</xsl:template>
</xsl:stylesheet>


Current (Broken) Result
<HTML xmlns:dxl="http://www.lotus.com/dxl">
<HEAD>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<TITLE>Blog</TITLE>
</HEAD>
<BODY bgcolor="#ffffff" marginheight="0" marginwidth="0" leftmargin="0" topmargin="0">
<TABLE width="100%" cellpadding="0" cellspacing="0" border="0">
<TR>
<TD border="0"><A href="">
<BR>
</A></TD>
</TR>
<TR>
<TD border="0"><A href="">
<BR>
</A></TD>
</TR>
</TABLE>
</BODY>
</HTML>

Any thoughts of suggestions most appreciated.

Ta
Glenn






XSLT Transformations of Notes 6 DXL... (~Lex Kihipitex 24.Oct.02)
. . RE: XSLT Transformations of Notes 6... (~Justin Quetjip... 24.Oct.02)
. . XML namespaces FAQ (~Lex Ekweberg 24.Oct.02)
. . It is working according to spec. (~Olga Kikrotern... 24.Oct.02)
. . . . RE: It is working according to spec... (~Ethan Zenfreet... 10.Dec.02)
. . . . Ok, that works but Default Namespac... (~Lex Kihipitex 25.Oct.02)
. . . . . . Setting xmlns="http://www.lotus.com... (~Olga Kikrotern... 29.Oct.02)
. . . . . . . . But may-be xmlns and xmlns:dxl? (~Delores Zenkro... 15.Nov.03)
. . RE: XSLT Transformations of Notes 6... (~Autumn Rejipyp... 24.Oct.02)
. . RE: XSLT Transformations of Notes 6... (~Yentl Rekrovit... 24.Oct.02)
. . . . RE: XSLT Transformations of Notes 6... (~Justin Quetjip... 24.Oct.02)
. . Working Version of XSLT Transformat... (~Lex Kihipitex 25.Oct.02)
. . . . Glenn, I said the same thing about ... (~Justin Quetjip... 25.Oct.02)





  Document options
Print this pagePrint this page

 Search this forum

  Forum views and search
Date (threaded)
Date (flat)
With excerpt
Category
Platform
Release
Advanced search

 RSS feedsRSS
All forum posts RSS
All main topics RSS